# Top Navigation
Applies a top navigation configuration template to a SharePoint site by processing rows from an Excel file. The navigation items (titles, URLs, and structure) are defined entirely within the template in config.json, not in the Excel row.
Filename pattern: filename must contain topnavigation (case-insensitive).
Example: 20240115 TopNavigation nav.xlsx
# Columns
| Name | Required | Description |
|---|---|---|
| ClientCode | No | Client identifier used together with MatterCode to look up the site URL from the matter list. |
| MatterCode | Conditional | Matter identifier. Required when Url is not provided. The site URL is resolved from the matter list. |
| Url / SiteUrl | Conditional | Server-relative URL of the target SharePoint site. Required when MatterCode is not provided. |
| SiteSet / SiteCfg | Yes | Name of a SiteCfg template from config.json. The top navigation nodes defined in that template are applied to the site. |
| RemoveAll | No | Boolean. When true, all existing top navigation items are removed before the template's nodes are applied. Defaults to false. |
Either Url or MatterCode must be provided. SiteSet is always required.
Any additional columns are passed as properties to the site configuration template for dynamic value substitution.
# Behavior
When only MatterCode is given, the handler looks up the site URL from the matter list. If the matter is not found or has no site URL, the row fails.
If the named template is not found in config.json, the row fails.
# Related links
- Site Configuration — defines the navigation items within
SiteCfgtemplates - Quick Launch Navigation handler — applies quick launch (left sidebar) navigation using the same template approach